<?php

class Application_Form_Salebill extends Zend_Form {
    
    public function init() {
        $this->setName('Salebill');
        
        $salebill_id = new Zend_Form_Element_Hidden('salebill_id');
        $salebill_date_created = new Zend_Form_Element_Hidden('salebill_date_created');
        $user_id_employee = new Zend_Form_Element_Text('user_id_employee');
                $user_id_employee->setLabel('ID Người lập :')
                                 ->setRequired(true)
              					 //->addFilters(array('StripTags', 'StringTrim', 'Int'))
              					 ->addValidator('NotEmpty');
              	  				                
		$user_id_customer = new Zend_Form_Element_Text('user_id_customer');
        $user_id_customer->setLabel('ID Khách hàng :')
                                 ->setRequired(true)
              					 //->addFilters(array('StripTags', 'StringTrim', 'Int'))
              					 ->addValidator('NotEmpty');
              	  				  
        $salebill_total = new Zend_Form_Element_Text('salebill_total');
        $salebill_total->setLabel('Tổng tiền hóa đơn :')
        						->setRequired(true) 
        						->addValidator('NotEmpty');
			
        $btn_submit = new Zend_Form_Element_Submit('submit');
        $btn_submit->setAttrib('id', 'submit');
        $btn_submit->setlabel('Đồng ý');

        $btn_cancel = new Zend_Form_Element_Submit('cancel');
        $btn_cancel->setAttrib('id', 'cancel');
        $btn_cancel->setLabel('Hủy bỏ');
        
        $this->addElements(array($salebill_id,$user_id_employee,$user_id_customer ,$salebill_date_created, $salebill_total, $btn_submit, $btn_cancel));
    }
}